package cn.wolfcode.luowowo.article.domain;

import cn.wolfcode.luowowo.common.domain.BaseDomain;
import cn.wolfcode.luowowo.member.domain.UserInfo;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;


/**
 * 问题的回答
 */
@Setter
@Getter
@ToString
public class WendaAnswer extends BaseDomain {

    public static final int WenDa_ANSWER_TYPE_COMMON = 0; //普通回答
    public static final int WenDa_ANSWER_TYPE = 1; //回答的回复

    private Question question;  //问题id
    private UserInfo user;    //用户id
    private Destination dest;    //目的地

    private String questionTitle; //问题标题
    private int type = WenDa_ANSWER_TYPE_COMMON; //回答类别

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date answerTime; //回答时间
    private String content;  //回答内容


}